<!DOCTYPE html>
<html lang="en">

<head>
  <meta charset="UTF-8">
  <meta name="viewport" content="width=device-width, initial-scale=1.0">
  <title>Document</title>
  <style>
    .hr {
      width: 300px;
      background-color: #000;
    }

    .half-px {
      height: 0.5px;
    }

    .one-px {
      height: 1px;
    }

    .scale-half {
      height: 1px;
      transform: scaleY(0.5);
    }

    .hr.boxshadow {
      height: 1px;
      background: none;
      box-shadow: 0 0.5px 0 #000;
    }

  </style>
</head>

<body>
  <p>0.5px</p>
  <div class="hr half-px"></div>
  <p>1px</p>
  <div class="hr one-px"></div>
  <p>1px+scaleY(0.5)</p>
  <div class="hr scale-half"></div>
  <p>box-shadow: 0 0.5px 0 #000</p>
  <div class="hr boxshadow"></div>
</body>

</html>